package com.dingreading.cloud.ssxcx.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.mybatisflex.annotation.Column;
import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 小程序课中题目选项表 实体类。
 *
 * @author EDY
 * @since 2025-08-15
 */
@Data
@Table(value = "xcx_lesson_quiz_options",dataSource = "ds3")
public class XcxLessonQuizOptions implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * ID，主键自增
     */
    @Id(keyType = KeyType.Auto)
    private Long id;

    /**
     * 选项的唯一UID
     */
    private String uid;

    /**
     * 关联的题目UID (对应 xcx_lesson_materials.uid)
     */
    private String questionUid;

    /**
     * 关联的课节UID
     */
    private String subjectLessonUid;

    /**
     * 选项内容
     */
    private String optionContent;

    /**
     * 是否为正确答案: 0-否, 1-是
     */
    private Boolean isCorrect;

    /**
     * 启用状态：0-禁用，1-启用
     */
    private Integer enabled;

    /**
     * 创建时间
     */
    @Column(onInsertValue = "now()")
    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private Date addTime;

    /**
     * 最后修改时间
     */
    @Column(onInsertValue = "now()", onUpdateValue = "now()")
    @JsonFormat(locale = "zh", timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private Date editTime;

    /**
     * 添加人用户ID
     */
    private String addStaffUid;

    /**
     * 添加人姓名
     */
    private String addStaffName;

    /**
     * 最后修改人用户ID
     */
    private String lastStaffUid;

    /**
     * 最后修改人姓名
     */
    private String lastStaffName;

    /**
     * 选项图片URL
     */
    private String url;

}
